package com.lzh.educms.client;

import com.lzh.commonutils.CommonResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.multipart.MultipartFile;

@Component
//调用服务的名称
@FeignClient(name = "service-oss")
public interface OssClient {
    @PostMapping("/edu/upload")
    public CommonResult uploadAvatar(MultipartFile file);

    @DeleteMapping("/eduOss/delete")
    public CommonResult deleteAvatar(@RequestParam("filePath") String filePath);

}
